feat(clerk-js): Include current search params in handleRedirectCallback#7600
feat(clerk-js): Include current search params in handleRedirectCallback#7600jfoshee wants to merge 2 commits intorelease/core-2from
handleRedirectCallback#7600Conversation
…ack` so that component `AuthenticateWithRedirectCallback` automatically incorporates any redirects in the current query to match the documented usage https://clerk.com/docs/guides/development/custom-flows/authentication/oauth-connections
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Comment |
handleRedirectCallbackhandleRedirectCallback
…ails-for-new-users-custom-sso
@clerk/agent-toolkit
@clerk/astro
@clerk/backend
@clerk/chrome-extension
@clerk/clerk-js
@clerk/dev-cli
@clerk/elements
@clerk/clerk-expo
@clerk/expo-passkeys
@clerk/express
@clerk/fastify
@clerk/localizations
@clerk/nextjs
@clerk/nuxt
@clerk/clerk-react
@clerk/react-router
@clerk/remix
@clerk/shared
@clerk/tanstack-react-start
@clerk/testing
@clerk/themes
@clerk/types
@clerk/upgrade
@clerk/vue
commit: |
so that component
AuthenticateWithRedirectCallbackautomatically incorporates any redirects in the current query to match the documented usagePart of USER-4308
Without a fix like this the developer must manually snag and specify all the possible redirects, which I think is not the intent of the component.
Note to Reviewers
❓ Is this the best place to insert the URL's query params? It could be done at a higher level, e.g. adding an argument to
handleRedirectCallback. Are there scenarios where it is undesirable to automatically use the window's current query?❓ What are some scenarios I should manually test?
It would be helpful to consider this change in conjunction with this docs change. I acknowledge that the change to the docs is not ideal; it makes the code example much longer. But, my thinking is to first: make it correct, second: make SDK improvements that could reduce the burden on customers.
Checklist
pnpm testruns as expected.pnpm buildruns as expected.Type of change